package lyo.levelup.swing.classwork;

import java.awt.BorderLayout;
import javax.swing.JButton;
import javax.swing.JPanel;

public class JavaComponent extends JPanel
{
    public JavaComponent()
    {
        addButtons();
    }
    private void addButtons()
    {
        JPanel buttonPanel = new JPanel();
        JButton b1 = new JButton("OK");
        JButton b2 = new JButton("CANCEL");
        setLayout(new BorderLayout());
        buttonPanel.add(b1);
        buttonPanel.add(b2);
        /*add(b1,BorderLayout.SOUTH);
        add(b2, BorderLayout.CENTER);*/
        add(buttonPanel, BorderLayout.SOUTH);
    }
}